package club.caihappy.pojo;

import lombok.Data;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

/**
 * Created by DELL on 2021/10/10
 **/
@Component
//@Data
public class Boss {

    // @Autowired
    private Car car;

    // @Autowired
    public Boss(Car car) {
        this.car = car;
        System.out.println("Boss...有参构造器");
    }

//    public Car getCar() {
//        return car;
//    }
//
//    //    @Autowired
//    public void setCar(Car car) {
//        this.car = car;
//    }

    @Override
    public String toString() {
        return "Boss{" +
                "car=" + car +
                '}';
    }
}
